
from twisted.python import log
from twisted.internet import reactor
import sys, socket

import common, slave

slave_config = common.Config( 'config.xml', 'config' ).getSection( 'slave' )

log.startLogging(sys.stdout)
sclient = slave.SlaveClient( socket.gethostname(), slave_config['resource'], 'password', slave_config['master']['jid'], slave_config['server']['ip'], slave_config['server']['port'], trigger_config = ( 'trigger_config' in slave_config and slave_config['trigger_config'] ) or False )
reactor.run()